import Vue from 'vue'
import App from './App'
import router from './router'
//import store from './store'
import "@/assets/css/reset.css";
import "../../assets/fonts/iconfont.css";


import 'element-ui/lib/theme-chalk/index.css';
import ElementUI from 'element-ui';
Vue.use(ElementUI);

import Popup from "./component/popup";
Vue.component('Popup',Popup);

//加载配置文件
import config from "@/config";
Vue.use(config);

import {Pagination,Row,Col} from 'element-ui';
Vue.use(Pagination);
Vue.use(Row);
Vue.use(Col);

import mixins from "@/mixins";
Vue.use(mixins);

//全局的过滤器
import filters from "@/filters";
Object.keys(filters).forEach(key=>{
    Vue.filter(key,filters[key]);
});

Vue.filter('getName',(val)=>{
    return val.length > 4 ? val.substr(0,4) : val;
});

import 'vue-layer/lib/vue-layer.css';
import layer from 'vue-layer'
Vue.prototype.$layer = layer(Vue);


var mixin = {
    methods:{
       //返回
       onClickLeft(){
           //this.$router.back();
       }
   }
};


Vue.config.productionTip = false;
new Vue({
    router,
    mixins: [mixin],
    render: h => h(App)
}).$mount('#app');